A voice encoder is good at encoding voice-type audio signals under mid-to-low bit rates, while has a poor effect on encoding music-type audio signals. An audio encoder is applicable to encoding of the voice-type and music-type audio signals under a high bit rate, but has an unsatisfactory effect on encoding the voice-type audio signals under the mid-to-low bit rates. In order to achieve a satisfactory encoding effect on audio signals mixed by voice and audio under the mid-to-low bit rates, an encoding process that is applicable to the voice/audio encoder under the mid-to-low bit rates mainly includes: first judging a type of an audio signal by using a signal classification module, and then selecting a corresponding encoding method according to the judged type of the audio signal, and selecting a voice encoder for the voice-type audio signal, and selecting an audio encoder for the music-type audio signal.
In the prior art, a method for judging the type of the audio signal mainly includes:
1. Divide an input signal into a series of overlapping frames by using a window function.
2. Calculate a spectral coefficient of each frame by using Fast Fourier Transform (FFT).
3. Calculate characteristic parameters in five aspects for each segment according to the spectral coefficient of each frame, namely, harmony, noise, tail, drag out and rhythm.
4. Divide the audio signal into six types based on values of the characteristic parameters, including a voice type, a music type, a noise type, a short segment, a segment to be determined, and a short segment to be determined.
During implementation of judging the type of the audio signal, the inventor finds that the prior art at least has the following problems: In the method, characteristic parameters of multiple aspects need to be calculated during a classification process; audio signal classification is complex, which result in high complexity of the classification.